from typing import List

from tortoise import BaseDBAsyncClient


async def upgrade(db: BaseDBAsyncClient) -> List[str]:
    return [
        """ALTER TABLE `users` ADD `role` VARCHAR(11) NOT NULL  COMMENT '用户角色' DEFAULT 'customer'"""
    ]


async def downgrade(db: BaseDBAsyncClient) -> List[str]:
    return [
        """ALTER TABLE `users` DROP COLUMN `role`"""
    ]
